3.72 \(\int \frac{1}{(d+e x^n) (a+b x^n+c x^{2 n})} \, dx\)

Optimal. Leaf size=243 \[ -\frac{c x \left (2 c d-e \left (\sqrt{b^2-4 a c}+b\right )\right ) \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{2 c x^n}{b-\sqrt{b^2-4 a c}}\right )}{\left (-b \sqrt{b^2-4 a c}-4 a c+b^2\right ) \left (a e^2-b d e+c d^2\right )}-\frac{c x \left (\frac{2 c d-b e}{\sqrt{b^2-4 a c}}+e\right ) \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{2 c x^n}{b+\sqrt{b^2-4 a c}}\right )}{\left (\sqrt{b^2-4 a c}+b\right ) \left (a e^2-b d e+c d^2\right )}+\frac{e^2 x \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{e x^n}{d}\right )}{d \left (a e^2-b d e+c d^2\right )} \]

[Out]

-((c*(2*c*d - (b + Sqrt[b^2 - 4*a*c])*e)*x*Hypergeometric2F1[1, n^(-1), 1 + n^(-1), (-2*c*x^n)/(b - Sqrt[b^2 -
 4*a*c])])/((b^2 - 4*a*c - b*Sqrt[b^2 - 4*a*c])*(c*d^2 - b*d*e + a*e^2))) - (c*(e + (2*c*d - b*e)/Sqrt[b^2 - 4
*a*c])*x*Hypergeometric2F1[1, n^(-1), 1 + n^(-1), (-2*c*x^n)/(b + Sqrt[b^2 - 4*a*c])])/((b + Sqrt[b^2 - 4*a*c]
)*(c*d^2 - b*d*e + a*e^2)) + (e^2*x*Hypergeometric2F1[1, n^(-1), 1 + n^(-1), -((e*x^n)/d)])/(d*(c*d^2 - b*d*e
+ a*e^2))

________________________________________________________________________________________

Rubi [A]  time = 0.469391, antiderivative size = 243, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 3, integrand size = 26, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.115, Rules used = {1424, 245, 1422} \[ -\frac{c x \left (2 c d-e \left (\sqrt{b^2-4 a c}+b\right )\right ) \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{2 c x^n}{b-\sqrt{b^2-4 a c}}\right )}{\left (-b \sqrt{b^2-4 a c}-4 a c+b^2\right ) \left (a e^2-b d e+c d^2\right )}-\frac{c x \left (\frac{2 c d-b e}{\sqrt{b^2-4 a c}}+e\right ) \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{2 c x^n}{b+\sqrt{b^2-4 a c}}\right )}{\left (\sqrt{b^2-4 a c}+b\right ) \left (a e^2-b d e+c d^2\right )}+\frac{e^2 x \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{e x^n}{d}\right )}{d \left (a e^2-b d e+c d^2\right )} \]

Antiderivative was successfully verified.

[In]

Int[1/((d + e*x^n)*(a + b*x^n + c*x^(2*n))),x]

[Out]

-((c*(2*c*d - (b + Sqrt[b^2 - 4*a*c])*e)*x*Hypergeometric2F1[1, n^(-1), 1 + n^(-1), (-2*c*x^n)/(b - Sqrt[b^2 -
 4*a*c])])/((b^2 - 4*a*c - b*Sqrt[b^2 - 4*a*c])*(c*d^2 - b*d*e + a*e^2))) - (c*(e + (2*c*d - b*e)/Sqrt[b^2 - 4
*a*c])*x*Hypergeometric2F1[1, n^(-1), 1 + n^(-1), (-2*c*x^n)/(b + Sqrt[b^2 - 4*a*c])])/((b + Sqrt[b^2 - 4*a*c]
)*(c*d^2 - b*d*e + a*e^2)) + (e^2*x*Hypergeometric2F1[1, n^(-1), 1 + n^(-1), -((e*x^n)/d)])/(d*(c*d^2 - b*d*e
+ a*e^2))

Rule 1424

Int[((d_) + (e_.)*(x_)^(n_))^(q_)/((a_) + (b_.)*(x_)^(n_) + (c_.)*(x_)^(n2_)), x_Symbol] :> Int[ExpandIntegran
d[(d + e*x^n)^q/(a + b*x^n + c*x^(2*n)), x], x] /; FreeQ[{a, b, c, d, e, n}, x] && EqQ[n2, 2*n] && NeQ[b^2 - 4
*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && IntegerQ[q]

Rule 245

Int[((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[a^p*x*Hypergeometric2F1[-p, 1/n, 1/n + 1, -((b*x^n)/a)],
x] /; FreeQ[{a, b, n, p}, x] &&  !IGtQ[p, 0] &&  !IntegerQ[1/n] &&  !ILtQ[Simplify[1/n + p], 0] && (IntegerQ[p
] || GtQ[a, 0])

Rule 1422

Int[((d_) + (e_.)*(x_)^(n_))/((a_) + (b_.)*(x_)^(n_) + (c_.)*(x_)^(n2_)), x_Symbol] :> With[{q = Rt[b^2 - 4*a*
c, 2]}, Dist[e/2 + (2*c*d - b*e)/(2*q), Int[1/(b/2 - q/2 + c*x^n), x], x] + Dist[e/2 - (2*c*d - b*e)/(2*q), In
t[1/(b/2 + q/2 + c*x^n), x], x]] /; FreeQ[{a, b, c, d, e, n}, x] && EqQ[n2, 2*n] && NeQ[b^2 - 4*a*c, 0] && NeQ
[c*d^2 - b*d*e + a*e^2, 0] && (PosQ[b^2 - 4*a*c] ||  !IGtQ[n/2, 0])

Rubi steps

\begin{align*} \int \frac{1}{\left (d+e x^n\right ) \left (a+b x^n+c x^{2 n}\right )} \, dx &=\int \left (\frac{e^2}{\left (c d^2-b d e+a e^2\right ) \left (d+e x^n\right )}+\frac{c d-b e-c e x^n}{\left (c d^2-b d e+a e^2\right ) \left (a+b x^n+c x^{2 n}\right )}\right ) \, dx\\ &=\frac{\int \frac{c d-b e-c e x^n}{a+b x^n+c x^{2 n}} \, dx}{c d^2-b d e+a e^2}+\frac{e^2 \int \frac{1}{d+e x^n} \, dx}{c d^2-b d e+a e^2}\\ &=\frac{e^2 x \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{e x^n}{d}\right )}{d \left (c d^2-b d e+a e^2\right )}-\frac{\left (c \left (e-\frac{2 c d-b e}{\sqrt{b^2-4 a c}}\right )\right ) \int \frac{1}{\frac{b}{2}-\frac{1}{2} \sqrt{b^2-4 a c}+c x^n} \, dx}{2 \left (c d^2-b d e+a e^2\right )}-\frac{\left (c \left (e+\frac{2 c d-b e}{\sqrt{b^2-4 a c}}\right )\right ) \int \frac{1}{\frac{b}{2}+\frac{1}{2} \sqrt{b^2-4 a c}+c x^n} \, dx}{2 \left (c d^2-b d e+a e^2\right )}\\ &=-\frac{c \left (e-\frac{2 c d-b e}{\sqrt{b^2-4 a c}}\right ) x \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{2 c x^n}{b-\sqrt{b^2-4 a c}}\right )}{\left (b-\sqrt{b^2-4 a c}\right ) \left (c d^2-b d e+a e^2\right )}-\frac{c \left (e+\frac{2 c d-b e}{\sqrt{b^2-4 a c}}\right ) x \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{2 c x^n}{b+\sqrt{b^2-4 a c}}\right )}{\left (b+\sqrt{b^2-4 a c}\right ) \left (c d^2-b d e+a e^2\right )}+\frac{e^2 x \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{e x^n}{d}\right )}{d \left (c d^2-b d e+a e^2\right )}\\ \end{align*}

Mathematica [A]  time = 0.447375, size = 200, normalized size = 0.82 \[ \frac{x \left (-\frac{c \left (\frac{b e-2 c d}{\sqrt{b^2-4 a c}}+e\right ) \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};\frac{2 c x^n}{\sqrt{b^2-4 a c}-b}\right )}{b-\sqrt{b^2-4 a c}}-\frac{c \left (\frac{2 c d-b e}{\sqrt{b^2-4 a c}}+e\right ) \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{2 c x^n}{b+\sqrt{b^2-4 a c}}\right )}{\sqrt{b^2-4 a c}+b}+\frac{e^2 \, _2F_1\left (1,\frac{1}{n};1+\frac{1}{n};-\frac{e x^n}{d}\right )}{d}\right )}{e (a e-b d)+c d^2} \]

Antiderivative was successfully verified.

[In]

Integrate[1/((d + e*x^n)*(a + b*x^n + c*x^(2*n))),x]

[Out]

(x*(-((c*(e + (-2*c*d + b*e)/Sqrt[b^2 - 4*a*c])*Hypergeometric2F1[1, n^(-1), 1 + n^(-1), (2*c*x^n)/(-b + Sqrt[
b^2 - 4*a*c])])/(b - Sqrt[b^2 - 4*a*c])) - (c*(e + (2*c*d - b*e)/Sqrt[b^2 - 4*a*c])*Hypergeometric2F1[1, n^(-1
), 1 + n^(-1), (-2*c*x^n)/(b + Sqrt[b^2 - 4*a*c])])/(b + Sqrt[b^2 - 4*a*c]) + (e^2*Hypergeometric2F1[1, n^(-1)
, 1 + n^(-1), -((e*x^n)/d)])/d))/(c*d^2 + e*(-(b*d) + a*e))

________________________________________________________________________________________

Maple [F]  time = 0.06, size = 0, normalized size = 0. \begin{align*} \int{\frac{1}{ \left ( d+e{x}^{n} \right ) \left ( a+b{x}^{n}+c{x}^{2\,n} \right ) }}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(d+e*x^n)/(a+b*x^n+c*x^(2*n)),x)

[Out]

int(1/(d+e*x^n)/(a+b*x^n+c*x^(2*n)),x)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{1}{{\left (c x^{2 \, n} + b x^{n} + a\right )}{\left (e x^{n} + d\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(d+e*x^n)/(a+b*x^n+c*x^(2*n)),x, algorithm="maxima")

[Out]

integrate(1/((c*x^(2*n) + b*x^n + a)*(e*x^n + d)), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{1}{b e x^{2 \, n} + a d +{\left (c e x^{n} + c d\right )} x^{2 \, n} +{\left (b d + a e\right )} x^{n}}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(d+e*x^n)/(a+b*x^n+c*x^(2*n)),x, algorithm="fricas")

[Out]

integral(1/(b*e*x^(2*n) + a*d + (c*e*x^n + c*d)*x^(2*n) + (b*d + a*e)*x^n), x)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(d+e*x**n)/(a+b*x**n+c*x**(2*n)),x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{1}{{\left (c x^{2 \, n} + b x^{n} + a\right )}{\left (e x^{n} + d\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(d+e*x^n)/(a+b*x^n+c*x^(2*n)),x, algorithm="giac")

[Out]

integrate(1/((c*x^(2*n) + b*x^n + a)*(e*x^n + d)), x)